open(BUFF,"SNP.txt");
open(WRBUFF,">SNP_GENODOS.txt");
$line=<BUFF>;
print WRBUFF $line;
while(<BUFF>)
{
	chomp($_);
	@a = split(/\t/,$_);
	print WRBUFF $a[0];
	for($i=1;$i<@a;$i++)
	{
		if($a[$i] <= 0.5)
		{
			print WRBUFF "\t0";
		}
		elsif($a[$i] <1.5)
		{
			print WRBUFF "\t1";
		}
		else
		{
			print WRBUFF "\t2";
		}
	}
	print WRBUFF "\n";
	
}
close(BUFF);
close(WRBUFF);
